package com.rc.evcharger.service.rc;

import com.rc.evcharger.mapper.rc.RcEnterpriseLevelSettingMapper;
import com.rc.evcharger.model.rc.RcEnterpriseLevelSetting;
import com.rc.evcharger.model.rc.RcEnterpriseLevelSettingExample;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class RcEnterpriseLevelSettingServiceImpl implements RcEnterpriseLevelSettingService {
    @Autowired
    private RcEnterpriseLevelSettingMapper rcEnterpriseLevelSettingMapper;

    @Override
    public RcEnterpriseLevelSettingMapper getMapper() {
        return rcEnterpriseLevelSettingMapper;
    }

    @Override
    public List<RcEnterpriseLevelSetting> listByDefault() {
        RcEnterpriseLevelSettingExample example = new RcEnterpriseLevelSettingExample();
        example.createCriteria().andStatusEqualTo("0");
        example.setOrderByClause("sort");
        return rcEnterpriseLevelSettingMapper.selectByExample(example);
    }
}
